function score = get_pre_score( train,uid,iid )
%UNTITLED5 Summary of this function goes here
%   Detailed explanation goes here
df1 = train(train(:,2)==iid,:);
[m,~] = size(df1);
sims = zeros(m,1);
for i = 1:m
    if df1(i,1)==uid
        continue
    end
    sims(i) = sim_pearson(train,uid,df1(i,1));
end
ss = (sims(sims>0)).*(df1(sims>0,3));
score = sum(ss)/sum(sims(sims>0));
end

